<?php
/**
 * @Copyright: (C)2021 BJYHYY Inc. All Rights Reserved.
 * @Author: xuzy
 * @Date: 2021/11/16 19:17
 */

namespace App\Model;
use Illuminate\Database\Eloquent\Model;

class Orders extends Model
{
    protected $table = 'orders';

    public const STATUS_WAIT_PAY = 0; //待支付
    public const STATUS_WAIT_DELIVER = 1; //待发货
    public const STATUS_DELIVER = 2; //配送中
    public const STATUS_COMPLETE = 3; //已完成
    public const STATUS_REFUSE = 4; // 已退款

    public function orderGoods()
    {
        return $this->hasMany(OrderGoods::class,'order_id','id');
    }


}